package com.eastfair.venuebooking.vo;

import com.eastfair.annotation.annotation.dictionary.DictionaryField;
import com.eastfair.annotation.annotation.vo.VoInfo;
import com.eastfair.venuebooking.demand.PriceListSpaceGroup;
import com.eastfair.venuebooking.demand.QuotationGroup;
import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.*;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.List;

/**
 * 价目场地 VO.
 *
 * @author dqq
 * @date 2022 /6/21
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = false)
@Builder
public class PriceListSpaceVO implements Serializable {

    /**
     * 场地价目关系id
     */
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Long id;

    /**
     * 场地id
     */
    @VoInfo(groups = {QuotationGroup.QueryPriceListSpace.class,
            PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Long spaceId;

    /**
     * 场地名称
     */
    @VoInfo(groups = {QuotationGroup.QueryPriceListSpace.class,
            PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String spaceName;

    /**
     * 价目id
     */
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Long priceListId;

    /**
     * 价目名称
     */
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String priceListName;

    /**
     * 场地计价面积
     */
    @VoInfo(groups = {QuotationGroup.QueryPriceListSpace.class,
            PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Double priceArea;

    /**
     * 价目单位编码
     */
    @DictionaryField(type = "PRICE_CONFIG")
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String unitCode;

    /**
     * 价目标准单价
     */
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Double unitPrice;

    /**
     * 场地保证金
     */
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Double spaceDeposit;

    /**
     * 服务保证金
     */
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Double serviceAdvanceCharge;

    /**
     * 总价
     */
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Double totalPrice;

    /**
     * 标签
     */
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String tag;

    /**
     * 场地分类id
     */
    @VoInfo(groups = {QuotationGroup.QueryPriceListSpace.class,
            PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Long spaceCategoryId;

    /**
     * 分类名称
     */
    @VoInfo(groups = {QuotationGroup.QueryPriceListSpace.class,
            PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String spaceCategoryName;

    /**
     * 场地计价单位与单价列表
     */
    @VoInfo(groups = {PriceListSpaceGroup.QueryPriceListSpace.class})
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private List<SpacePriceUnitVO> spacePriceUnitList;
}
